package com.springinaction.knights;

import org.springframework.context.support.ClassPathXmlApplicationContext;

public class KnightMain {

    public static void main(String[] args) throws Exception{
        ClassPathXmlApplicationContext context = new ClassPathXmlApplicationContext(
                "META-INF/spring/knights.xml"
        );
        Knight knight = context.getBean(Knight.class);
        System.out.println("start");

        knight.embarkOnQuest();
        System.out.println("end");
        context.close();
    }
}
